import Vue from "vue";
import VueRouter from "vue-router";
import Home from "../views/Home.vue";
import Me from "../views/Me.vue";
import PlayListDetail from "../components/playlist/PlayListDetail.vue";
import RankListDetail from "../components/rank/RankListDetail/Player.vue";
import Player from '../components/player/player.vue'
Vue.use(VueRouter);
const routes = [{
        path: "/",
        name: "Home",
        component: Home
    },
    {
        path: "/rank",
        name: "Rank",
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () =>
            import ( /* webpackChunkName: "about" */ "../views/Rank.vue")
    },
    {
        path: "/me",
        name: "Me",
        component: Me
    },

    {
        path: "/playlistdetail/:id",
        name: "PlayListDetail",
        component: PlayListDetail
    }
];
{
    path: '/ranklistetail/:id',
    name: 'RankListDetail',
    component: RankListDetail
}

const router = new VueRouter({
    mode: "history",
    base: process.env.BASE_URL,
    routes
});


export default router